package com.lolineet.user.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import io.swagger.v3.oas.annotations.media.Schema;

/**
 * <p>
 * 
 * </p>
 *
 * @author lolineet
 * @since 2025-04-17
 */
@TableName("sys_menu")
@Schema(name = "SysMenu", description = "")
public class SysMenu implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private Long id;

    @Schema(description = "父菜单ID")
    private Long parentId;

    @Schema(description = "父节点ID路径")
    private String treePath;

    @Schema(description = "菜单名称")
    private String name;

    @Schema(description = "菜单类型(1:菜单 2:目录 3:外链 4:按钮)")
    private Byte type;

    @Schema(description = "路由路径(浏览器地址栏路径)")
    private String path;

    @Schema(description = "组件路径(vue页面完整路径，省略.vue后缀)")
    private String component;

    @Schema(description = "权限标识")
    private String perm;

    @Schema(description = "显示状态(1-显示;0-隐藏)")
    private Boolean visible;

    @Schema(description = "排序")
    private Integer sort;

    @Schema(description = "菜单图标")
    private String icon;

    @Schema(description = "跳转路径")
    private String redirect;

    @Schema(description = "创建时间")
    private LocalDateTime createTime;

    @Schema(description = "更新时间")
    private LocalDateTime updateTime;

    @Schema(description = "【目录】只有一个子路由是否始终显示(1:是 0:否)")
    private Byte alwaysShow;

    @Schema(description = "【菜单】是否开启页面缓存(1:是 0:否)")
    private Byte keepAlive;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getParentId() {
        return parentId;
    }

    public void setParentId(Long parentId) {
        this.parentId = parentId;
    }

    public String getTreePath() {
        return treePath;
    }

    public void setTreePath(String treePath) {
        this.treePath = treePath;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Byte getType() {
        return type;
    }

    public void setType(Byte type) {
        this.type = type;
    }

    public String getPath() {
        return path;
    }

    public void setPath(String path) {
        this.path = path;
    }

    public String getComponent() {
        return component;
    }

    public void setComponent(String component) {
        this.component = component;
    }

    public String getPerm() {
        return perm;
    }

    public void setPerm(String perm) {
        this.perm = perm;
    }

    public Boolean getVisible() {
        return visible;
    }

    public void setVisible(Boolean visible) {
        this.visible = visible;
    }

    public Integer getSort() {
        return sort;
    }

    public void setSort(Integer sort) {
        this.sort = sort;
    }

    public String getIcon() {
        return icon;
    }

    public void setIcon(String icon) {
        this.icon = icon;
    }

    public String getRedirect() {
        return redirect;
    }

    public void setRedirect(String redirect) {
        this.redirect = redirect;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public LocalDateTime getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(LocalDateTime updateTime) {
        this.updateTime = updateTime;
    }

    public Byte getAlwaysShow() {
        return alwaysShow;
    }

    public void setAlwaysShow(Byte alwaysShow) {
        this.alwaysShow = alwaysShow;
    }

    public Byte getKeepAlive() {
        return keepAlive;
    }

    public void setKeepAlive(Byte keepAlive) {
        this.keepAlive = keepAlive;
    }

    @Override
    public String toString() {
        return "SysMenu{" +
        "id = " + id +
        ", parentId = " + parentId +
        ", treePath = " + treePath +
        ", name = " + name +
        ", type = " + type +
        ", path = " + path +
        ", component = " + component +
        ", perm = " + perm +
        ", visible = " + visible +
        ", sort = " + sort +
        ", icon = " + icon +
        ", redirect = " + redirect +
        ", createTime = " + createTime +
        ", updateTime = " + updateTime +
        ", alwaysShow = " + alwaysShow +
        ", keepAlive = " + keepAlive +
        "}";
    }
}
